import { Inject, Controller ,Post ,Body} from '@midwayjs/decorator';
import { Context } from '@midwayjs/koa'
import { OSSService } from '@midwayjs/oss';
import { OssService } from '../../service/oss.service';

/**
 * 描述
 */
@Controller('/api')
// @Controller('/oss')
export class APIController {
 @Inject()
  ctx: Context;
  @Inject()
  OSSService:OSSService;

  @Inject()
  OssService:OssService

     /**
   * 上传oss文件
   */
@Post('/getoss' , { summary: '上传文件' })
async getoss( @Body() body) {
    return await this.OssService.getOss()
  }
}